import Vue from 'vue'
import Router from 'vue-router'
import Login from '@/components/login'
import Main from '@/components/main'
import Maindetail1 from '@/components/secfolder/main-detail1'
import Maindetail2 from '@/components/secfolder/main-detail2'
import Schedule from '@/components/schedule/schedule'
import Student from '@/components/student/student'
import SelectBirthday from '@/components/student/selectBirthday'
import AddStudent from '@/components/student/addstudent'
import AddStudentTime from '@/components/student/addstudentTime'

import TestBaiDu from '@/components/map/map'

import Index from '@/components/Index'
import AddSchedule from '@/components/schedule/addSchedule'
import ManageSchedule from '@/components/schedule/manageSchedule'


Vue.use(Router)



export default new Router({
  routes: [
    {
      path: '/',
      name: 'Index',
      component: Index
    },
    {
      path: '/pub/addSchedule',
      name: 'AddSchedule',
      component: AddSchedule
    },
    {
      path: '/pub/manageSchedule',
      name: 'ManageSchedule',
      component: ManageSchedule
    },
    {
      path: '/Main/student/addstudent',
      name: 'AddStudent',
      component: AddStudent
    },
    {
      path: '/Main/student/addstudentTime',
      name: 'AddStudentTime',
      component: AddStudentTime
    },
    {
      path: '/Main/student/selectBirthday',
      name: 'SelectBirthday',
      component: SelectBirthday
    },
    {
      path: '/Main',
      name: 'Main',
      component: Main,
      children:
      [
        {
          path: '/Main/detail1',
          name: 'Maindetail1',
          component: Maindetail1
        },
        {
          path: '/Main/detail2',
          name: 'Maindetail2',
          component: Maindetail2
        },
        {
          path: '/Main/schedule',
          name: 'Schedule',
          component: Schedule
        },
        {
          path: '/Main/student',
          name: 'Student',
          component: Student
        },
        {
          path: '/Main/map',
          name: 'TestBaiDu',
          component: TestBaiDu
        }
      ]
    },
    {
      path: '/Login',
      name: 'login',
      component: Login
    }
  ]
})
